package com.xmu.prcs.action.bean;
/**
 * 检索结果
 * @author frequent
 *
 */
public class RetrievalResultBean implements Comparable{

	private int idPlant;
	private String plantName;
	private int sumGrade;
	
	/**
	 * 实现Comparable接口，以便对性状重要性得分排序
	 */
	public int compareTo(Object o) {
		RetrievalResultBean result = (RetrievalResultBean)o;
		if(this.sumGrade > result.getSumGrade()){
			return 1;
		}
		if(this.sumGrade < result.getSumGrade()){
			return -1;
		}
		return 0;
	}

	public int getIdPlant() {
		return idPlant;
	}

	public void setIdPlant(int idPlant) {
		this.idPlant = idPlant;
	}

	public String getPlantName() {
		return plantName;
	}

	public void setPlantName(String plantName) {
		this.plantName = plantName;
	}

	public int getSumGrade() {
		return sumGrade;
	}

	public void setSumGrade(int sumGrade) {
		this.sumGrade = sumGrade;
	}
	
}
